import datetime
from applications.extensions import db


class Tag(db.Model):
    __tablename__ = 'blog_tag'
    id = db.Column(db.Integer, primary_key=True, autoincrement=True, comment="标签ID")
    name = db.Column(db.String(256), comment="分类名")
    is_del = db.Column(db.Integer, comment="状态(1删除,0未删)")
    create_at = db.Column(db.DateTime, default=datetime.datetime.now, comment='创建时间')
    update_at = db.Column(db.DateTime, default=datetime.datetime.now, onupdate=datetime.datetime.now, comment='更新时间')